// 引入mockjs
const Mock = require('mockjs')
// 获取 mock.Random 对象
const Random = Mock.Random
// mock一组数据
const personsData = function () {
  let persons = []
  for (let i = 0; i < 10; i++) {
    let newPersonObject = {
      Id: i,
      Name: Random.cname(), //  Random.csentence( min, max )
      Sex: Random.integer(0, 1) === 0 ? '女' : '男',
      BirthDay: Random.date('yyyy年MM月'),
      Age: Random.integer(20, 60),
      UnitName: Mock.mock('@county(true)')
    }
    persons.push(newPersonObject)
  }

  return {
    IsSuccess: true,
    Msg: '100',
    Result: persons
  }
}
const deleteData = function () {
  return {
    IsSuccess: true,
    Msg: '0',
    Result: null
  }
}
const userData = function () {
  let user = []
  for (let i = 0; i < 20; i++) {
    let newuserObject = {
      index: i,
      username: Random.last(), //  Random.csentence( min, max )
      realname: Random.cname(), //  Random.csentence( min, max )
      usertype: '录入员',
      active: '正常'
    }
    user.push(newuserObject)
  }
  return {
    IsSuccess: true,
    Msg: '20',
    Result: user
  }
}
const importuserData = function () {
  let importuser = []
  for (let i = 0; i < 20; i++) {
    let newimportuserObject = {
      index: i,
      Name: Random.cname(), //  Random.csentence( min, max )
      filename: Random.cname() + '.xls', //  Random.csentence( min, max )
      importresult: '成功'
    }
    importuser.push(newimportuserObject)
  }
  return {
    IsSuccess: true,
    Msg: '20',
    Result: importuser
  }
}
const loginData = function () {
  return {
    IsSuccess: true,
    Msg: 'OK'
  }
}
const xueliData = function () {
  let xueli = [{
    value: '名誉博士',
    label: '名誉博士'
  }, {
    value: '博士',
    label: '博士',
    children: [{
      value: '哲学博士',
      label: '哲学博士'
    }, {
      value: '经济学博士',
      label: '经济学博士'
    }, {
      value: '法学博士',
      label: '法学博士'
    }, {
      value: '教育学博士',
      label: '教育学博士'
    }, {
      value: '文学博士',
      label: '文学博士'
    }, {
      value: '历史学博士',
      label: '历史学博士'
    }, {
      value: '理学博士',
      label: '理学博士'
    }, {
      value: '工学博士',
      label: '工学博士'
    }, {
      value: '农学博士',
      label: '农学博士'
    }, {
      value: '医学博士',
      label: '医学博士'
    }, {
      value: '军事学博士',
      label: '军事学博士'
    }, {
      value: '管理学博士',
      label: '管理学博士'
    }, {
      value: '临床医学博士专业',
      label: '临床医学博士专业'
    }, {
      value: '兽医博士专业',
      label: '兽医博士专业'
    }, {
      value: '口腔医学博士专业',
      label: '口腔医学博士专业'
    }]
  }, {
    value: '硕士',
    label: '硕士',
    children: [{
      value: '哲学硕士',
      label: '哲学硕士'
    }, {
      value: '经济学硕士',
      label: '经济学硕士'
    }, {
      value: '法学硕士',
      label: '法学硕士'
    }, {
      value: '教育学硕士',
      label: '教育学硕士'
    }, {
      value: '文学硕士',
      label: '文学硕士'
    }, {
      value: '历史学硕士',
      label: '历史学硕士'
    }, {
      value: '理学硕士',
      label: '理学硕士'
    }, {
      value: '工学硕士',
      label: '工学硕士'
    }, {
      value: '农学硕士',
      label: '农学硕士'
    }, {
      value: '医学硕士',
      label: '医学硕士'
    }, {
      value: '军事学硕士',
      label: '军事学硕士'
    }, {
      value: '管理学硕士',
      label: '管理学硕士'
    }, {
      value: '法律硕士专业',
      label: '法律硕士专业'
    }, {
      value: '教育硕士专业',
      label: '教育硕士专业'
    }, {
      value: '工程硕士专业',
      label: '工程硕士专业'
    }, {
      value: '建筑学硕士专业',
      label: '建筑学硕士专业'
    }, {
      value: '临床医学硕士专业',
      label: '临床医学硕士专业'
    }, {
      value: '工商管理硕士专业',
      label: '工商管理硕士专业'
    }, {
      value: '农业推广硕士专业',
      label: '农业推广硕士专业'
    }, {
      value: '兽医硕士专业',
      label: '兽医硕士专业'
    }, {
      value: '公共管理硕士专业',
      label: '公共管理硕士专业'
    }, {
      value: '口腔医学硕士专业',
      label: '口腔医学硕士专业'
    }, {
      value: '公共卫生硕士专业',
      label: '公共卫生硕士专业'
    }, {
      value: '军事硕士专业',
      label: '军事硕士专业'
    }]
  }, {
    value: '学士',
    label: '学士',
    children: [{
      value: '哲学学士',
      label: '哲学学士'
    }, {
      value: '经济学学士',
      label: '经济学学士'
    }, {
      value: '法学学士',
      label: '法学学士'
    }, {
      value: '教育学学士',
      label: '教育学学士'
    }, {
      value: '文学学士',
      label: '文学学士'
    }, {
      value: '历史学学士',
      label: '历史学学士'
    }, {
      value: '理学学士',
      label: '理学学士'
    }, {
      value: '工学学士',
      label: '工学学士'
    }, {
      value: '农学学士',
      label: '农学学士'
    }, {
      value: '医学学士',
      label: '医学学士'
    }, {
      value: '军事学学士',
      label: '军事学学士'
    }, {
      value: '管理学学士',
      label: '管理学学士'
    }, {
      value: '建筑学学士专业',
      label: '建筑学学士专业'
    }]
  }]
  return {
    IsSuccess: true,
    Msg: '20',
    Result: xueli
  }
}
const xueweiData = function () {
  let xuewei = [{
    value: '研究生教育',
    label: '研究生教育',
    children: [{
      value: '研究生',
      label: '研究生'
    }, {
      value: '研究生班',
      label: '研究生班'
    }, {
      value: '中央党校研究生',
      label: '中央党校研究生'
    }, {
      value: '省（区、市）委党校研究生',
      label: '省（区、市）委党校研究生'
    }]
  }, {
    value: '本科教育',
    label: '本科教育',
    children: [{
      value: '大学',
      label: '大学'
    }, {
      value: '中央党校大学',
      label: '中央党校大学'
    }, {
      value: '省（区、市）委党校大学',
      label: '省（区、市）委党校大学'
    }]
  }, {
    value: '专科教育',
    label: '专科教育',
    children: [{
      value: '大专',
      label: '大专'
    }, {
      value: '省（区、市）委党校',
      label: '省（区、市）委党校'
    }, {
      value: '大学普通班',
      label: '大学普通班'
    }, {
      value: '中央党校大专',
      label: '中央党校大专'
    }]
  }, {
    value: '中专',
    label: '中专'
  }, {
    value: '中技',
    label: '中技'
  }, {
    value: '高中',
    label: '高中'
  }, {
    value: '初中',
    label: '初中'
  }, {
    value: '小学',
    label: '小学'
  }]
  return {
    IsSuccess: true,
    Msg: '20',
    Result: xuewei
  }
}

const minzuData = function () {
  let minzu = [{
    value: '汉族',
    label: '汉族'
  }, {
    value: '壮族',
    label: '壮族'
  }, {
    value: '满族',
    label: '满族'
  }, {
    value: '回族',
    label: '回族'
  }, {
    value: '苗族',
    label: '苗族'
  }, {
    value: '维吾尔族',
    label: '维吾尔族'
  }, {
    value: '土家族',
    label: '土家族'
  }, {
    value: '彝族',
    label: '彝族'
  }, {
    value: '蒙古族',
    label: '蒙古族'
  }, {
    value: '藏族',
    label: '藏族'
  }, {
    value: '布依族',
    label: '布依族'
  }, {
    value: '侗族',
    label: '侗族'
  }, {
    value: '瑶族',
    label: '瑶族'
  }, {
    value: '朝鲜族',
    label: '朝鲜族'
  }, {
    value: '白族',
    label: '白族'
  }, {
    value: '哈尼族',
    label: '哈尼族'
  }, {
    value: '哈萨克族',
    label: '哈萨克族'
  }, {
    value: '黎族',
    label: '黎族'
  }, {
    value: '傣族',
    label: '傣族'
  }, {
    value: '畲族',
    label: '畲族'
  }, {
    value: '僳僳族',
    label: '僳僳族'
  }, {
    value: '仡佬族',
    label: '仡佬族'
  }, {
    value: '东乡族',
    label: '东乡族'
  }, {
    value: '拉祜族',
    label: '拉祜族'
  }, {
    value: '水族',
    label: '水族'
  }, {
    value: '佤族',
    label: '佤族'
  }, {
    value: '纳西族',
    label: '纳西族'
  }, {
    value: '羌族',
    label: '羌族'
  }, {
    value: '土族',
    label: '土族'
  }, {
    value: '仫佬族',
    label: '仫佬族'
  }, {
    value: '锡伯族',
    label: '锡伯族'
  }, {
    value: '柯尔克孜族',
    label: '柯尔克孜族'
  }, {
    value: '达翰尔族',
    label: '达翰尔族'
  }, {
    value: '景颇族',
    label: '景颇族'
  }, {
    value: '毛南族',
    label: '毛南族'
  }, {
    value: '撒拉族',
    label: '撒拉族'
  }, {
    value: '布朗族',
    label: '布朗族'
  }, {
    value: '塔吉克族',
    label: '塔吉克族'
  }, {
    value: '阿昌族',
    label: '阿昌族'
  }, {
    value: '普米族',
    label: '普米族'
  }, {
    value: '鄂温克族',
    label: '鄂温克族'
  }, {
    value: '怒族',
    label: '怒族'
  }, {
    value: '京族',
    label: '京族'
  }, {
    value: '基诺族',
    label: '基诺族'
  }, {
    value: '德昂族',
    label: '德昂族'
  }, {
    value: '保安族',
    label: '保安族'
  }, {
    value: '俄罗斯族',
    label: '俄罗斯族'
  }, {
    value: '裕固族',
    label: '裕固族'
  }, {
    value: '乌孜别克族',
    label: '乌孜别克族'
  }, {
    value: '门巴族',
    label: '门巴族'
  }, {
    value: '鄂伦春族',
    label: '鄂伦春族'
  }, {
    value: '独龙族',
    label: '独龙族'
  }, {
    value: '塔塔尔族',
    label: '塔塔尔族'
  }, {
    value: '赫哲族',
    label: '赫哲族'
  }, {
    value: '高山族',
    label: '高山族'
  }, {
    value: '珞巴族',
    label: '珞巴族'
  }, {
    value: '其他族',
    label: '其他族'
  }, {
    value: '外国血统',
    label: '外国血统'
  }, {
    value: '外国民族',
    label: '外国民族'
  }, {
    value: '加入中国籍的外国人',
    label: '加入中国籍的外国人'
  }]
  return {
    IsSuccess: true,
    Msg: '20',
    Result: minzu
  }
}

const homenewsData = function () {
  let homenews = []
  for (let i = 0; i < 6; i++) {
    let newhomenewsObject = {
      title: Random.cparagraph(1), //  Random.csentence( min, max )
      newsdate: Random.date('yyyy年MM月dd日')
    }
    homenews.push(newhomenewsObject)
  }
  return {
    IsSuccess: true,
    Msg: '6',
    Result: homenews
  }
}

const jiatingData = function () {
  let jiating = []
  for (let i = 0; i < 4; i++) {
    let newjiatingObject = {
      index: i,
      Id: i,
      Chengwei: '家属',
      Name1: Random.cname(),
      Nianling: Random.integer(20, 60),
      Zhengzhimianmao: '党员',
      Gongzuodanwei: Random.csentence(5, 10)
    }
    jiating.push(newjiatingObject)
  }
  return {
    IsSuccess: true,
    Msg: '4',
    Result: jiating
  }
}
const jianliData = function () {
  let jianli = []
  for (let i = 0; i < 3; i++) {
    let newjianliObject = {
      index: i,
      Id: i,
      Shijian: Random.date('yyyy-MM') + '-' + Random.date('yyyy-MM'),
      jingliqingkuang: Random.csentence(5, 10)
    }
    jianli.push(newjianliObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: jianli
  }
}
const renzhiData = function () {
  let renzhi = []
  for (let i = 0; i < 3; i++) {
    let newrenzhiObject = {
      index: i,
      danwei: Random.csentence(5, 10),
      bumen: Random.csentence(5, 10),
      zhiwu: Random.csentence(5, 10)
    }
    renzhi.push(newrenzhiObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: renzhi
  }
}
const personData = function () {
  let newPersonObject = {
    Name: Random.cname(), //  Random.csentence( min, max )
    Sex: Random.integer(0, 1) === 0 ? '女' : '男',
    BirthDay: Random.date('yyyy年MM月'),
    Age: Random.integer(20, 60),
    UnitName: Mock.mock('@county(true)')
  }
  return {
    IsSuccess: true,
    Msg: '100',
    Result: newPersonObject
  }
}
const jianliDetailData = function () {
  let newjianliObject = {
    index: 1,
    Shijian: Random.date('yyyy-MM') + '-' + Random.date('yyyy-MM'),
    jingliqingkuang: Random.csentence(5, 10)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: newjianliObject
  }
}
const jiatingDetailData = function () {
  let newjiatingObject = {
    index: 1,
    chengwei: '母亲',
    name: Random.cname(),
    nianling: Random.integer(20, 60),
    zhengzhimianmao: '中共党员',
    gongzuodanwei: Random.csentence(5, 10)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: newjiatingObject
  }
}
const TreeData = function () {
  let treeObject = [
    {
      id: 1,
      order: 1,
      label: '分类1',
      title: '分类1',
      className: 'icon-wenjianjia1 tree-icon iconfont',
      depttype: '分类',
      children: [
        {
          id: 2,
          order: 3,
          label: '分类2',
          title: '分类2',
          className: 'icon-wenjianjia1 tree-icon iconfont',
          depttype: '分类',
          children: [
            {
              id: 3,
              order: 4,
              label: '单位1',
              title: '单位全称1',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            },
            {
              id: 4,
              order: 3,
              label: '单位2',
              title: '单位全称2',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            },
            {
              id: 11,
              order: 2,
              label: '单位3',
              title: '单位全称3',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            },
            {
              id: 12,
              order: 1,
              label: '单位4',
              title: '单位全称4',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            }
          ]
        },
        {
          id: 5,
          order: 2,
          label: '单位5',
          title: '单位全称5',
          className: 'icon-danwei tree-icon iconfont',
          depttype: '单位',
          children: [
            {
              id: 6,
              order: 2,
              label: '科室1',
              title: '科室全称1',
              className: 'icon-cf-c24 tree-icon iconfont',
              depttype: '部门'
            },
            {
              id: 7,
              order: 2,
              label: '科室2',
              title: '科室全称2',
              className: 'icon-cf-c24 tree-icon iconfont',
              depttype: '部门'
            }
          ]
        },
        {
          id: 8,
          order: 1,
          label: '单位6',
          title: '单位全称6',
          className: 'icon-danwei tree-icon iconfont',
          depttype: '单位',
          children: [
            {
              id: 9,
              order: 2,
              label: '单位7',
              title: '单位全称7',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            },
            {
              id: 10,
              order: 1,
              label: '单位8',
              title: '单位全称8',
              className: 'icon-danwei tree-icon iconfont',
              depttype: '单位'
            }
          ]
        }
      ]
    },
    {
      id: 0,
      order: 0,
      label: '无职务人员',
      title: '无职务人员',
      className: 'icon-qunzutianchong tree-icon iconfont',
      depttype: '无职务人员'
    }]
  return {
    IsSuccess: true,
    Msg: '3',
    Result: treeObject
  }
}
const TreeData0 = function () {
  let treeObject0 = [
    {
      id: 1,
      label: '分类1',
      title: '分类1',
      className: 'icon-wenjianjia1 tree-icon iconfont'
    },
    {
      id: 2,
      label: '分类2',
      title: '分类2',
      className: 'icon-wenjianjia1 tree-icon iconfont'
    },
    {
      id: 3,
      label: '分类3',
      title: '分类3',
      className: 'icon-wenjianjia1 tree-icon iconfont'
    },
    {
      id: 0,
      label: '无职务人员',
      title: '无职务人员',
      className: 'icon-qunzutianchong tree-icon iconfont'
    }
  ]
  return {
    IsSuccess: true,
    Msg: '3',
    Result: treeObject0
  }
}
const deptDetailData = function () {
  let mypost = []
  for (let i = 0; i < 20; i++) {
    let postObject = {
      index: i,
      name: Random.csentence(5, 10),
      post: Random.csentence(5, 10),
      type: Random.csentence(5, 10)
    }
    mypost.push(postObject)
  }
  let newdeptObject = {
    index: 1,
    Name: '测试单位',
    Jigouguige: Random.integer(20, 60),
    Jingneijingwai: '京内',
    Hangyeleibie: Random.csentence(5, 10),
    Shiyedanweileixing: Random.csentence(5, 10),
    depttype: '内设机构',
    zhize: Random.csentence(5000, 1000),
    post: mypost
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: newdeptObject
  }
}
const bzData = function () {
  let bz = []
  for (let i = 0; i < 3; i++) {
    let newbzObject = {
      index: i,
      Id: i,
      Fenlei: '事业编制',
      Shenfen: '测试身份',
      Zhiwujibie: '职务类别',
      Zhiwumingcheng: '职务名称',
      Renshu: 3,
      Remark: Random.csentence(5, 10)
    }
    bz.push(newbzObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: bz
  }
}
const bzDetailData = function () {
  let newbzObject = {
    index: 1,
    Id: 1,
    Fenlei: '事业编制',
    Shenfen: '测试身份',
    Zhiwujibie: '职务类别',
    Zhiwumingcheng: '职务名称',
    Renshu: 3,
    Remark: Random.csentence(5, 10)
  }
  return {
    IsSuccess: true,
    Msg: '1',
    Result: newbzObject
  }
}
const deptData = function () {
  let dept = []
  for (let i = 0; i < 3; i++) {
    let newdeptObject = {
      index: i,
      Id: i,
      parentDeptid: 5,
      parentDept: '测试上级单位',
      deptClass: '单位',
      Name: Random.csentence(5, 10)
    }
    dept.push(newdeptObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: dept
  }
}
const deptDetailData1 = function () {
  let newdeptObject = {
    index: 1,
    Id: 1,
    parentDeptid: 5,
    parentDept: '测试上级单位',
    deptClass: '单位',
    Name: Random.csentence(5, 10)
  }
  return {
    IsSuccess: true,
    Msg: '1',
    Result: newdeptObject
  }
}
const postsData = function () {
  let post = []
  for (let i = 0; i < 3; i++) {
    let newpostObject = {
      index: i,
      Id: i,
      zhiwei: '主任',
      checked: true,
      Name: Random.cname(),
      Sex: '男',
      BirthDay: Random.date('yyyy年MM月')
    }
    post.push(newpostObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: post
  }
}
const postsData2 = function () {
  let post = []
  for (let i = 0; i < 3; i++) {
    let newpostObject = {
      index: i,
      Id: i,
      zhiwei: '科员',
      checked: false,
      Name: Random.cname(),
      Sex: '男',
      BirthDay: Random.date('yyyy年MM月')
    }
    post.push(newpostObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: post
  }
}
const postsdetailData = function () {
  let newpostObject = {
    index: 1,
    postId: 1,
    personId: 5,
    zhiwei: '科员',
    checked: false,
    Name: Random.cname(),
    Sex: '男',
    BirthDay: Random.date('yyyy年MM月')
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: newpostObject
  }
}
const deptpersonsData = function () {
  let persons = []
  for (let i = 0; i < 5; i++) {
    let newPersonObject = {
      Id: i,
      Name: Random.cname(), //  Random.csentence( min, max )
      Sex: Random.integer(0, 1) === 0 ? '女' : '男',
      BirthDay: Random.date('yyyy年MM月'),
      Age: Random.integer(20, 60),
      UnitName: Mock.mock('@county(true)')
    }
    persons.push(newPersonObject)
  }

  return {
    IsSuccess: true,
    Msg: '100',
    Result: persons
  }
}
const docsData = function () {
  let doc = []
  for (let i = 0; i < 5; i++) {
    let docObject = {
      index: i,
      title: Random.csentence(5, 10),
      filename: Random.csentence(5, 10),
      zhiwu: Random.csentence(5, 10)
    }
    doc.push(docObject)
  }
  return {
    IsSuccess: true,
    Msg: '3',
    Result: doc
  }
}
const moredocsData = function () {
  let doc = []
  for (let i = 0; i < 20; i++) {
    let docObject = {
      index: i,
      year: 2018,
      title: Random.csentence(5, 10),
      Dept: Random.csentence(5, 10),
      Num: Random.csentence(5, 10),
      class1: Random.csentence(5, 10),
      class2: Random.csentence(5, 10),
      zhixing: '是',
      filename: Random.csentence(5, 10),
      zhiwu: Random.csentence(5, 10)
    }
    doc.push(docObject)
  }
  return {
    IsSuccess: true,
    Msg: '100',
    Result: doc
  }
}
const userListData = function () {
  let doc = []
  for (let i = 0; i < 20; i++) {
    let docObject = {
      index: i,
      UserName: Random.name(),
      TrueName: Random.cname(),
      UnitName: Random.csentence(5, 10),
      ZhiWu: Random.csentence(5, 5),
      RoleName2: Random.csentence(5, 10)
    }
    doc.push(docObject)
  }
  return {
    IsSuccess: true,
    Msg: '100',
    Result: doc
  }
}
const selectionListData = function () {
  let selection = []
  for (let i = 0; i < 20; i++) {
    let selectionObject = {
      index: i,
      Name: Random.cname(),
      UnitName: Random.csentence(5, 10),
      ZhiWu: Random.csentence(5, 5),
      RoleName2: Random.csentence(5, 10)
    }
    selection.push(selectionObject)
  }
  return {
    IsSuccess: true,
    Msg: '100',
    Result: selection
  }
}
const unitData = function () {
  console.log('成功mock')
  let units = []
  var unit = ''
  for (let i = 0; i < 20; i++) {
    unit = '单位' + i
    units.push(unit)
  }
  return {
    IsSuccess: true,
    Msg: '100',
    Result: units
  }
}
const checkresultData = function () {
  console.log('成功mock')
  return {
    IsSuccess: true,
    Msg: '100',
    result: true
  }
}

// Mock.mock( url, post/get , 返回的数据)；
Mock.mock('http://localhost/person/list', 'post', personsData)
Mock.mock('http://localhost/person/delete', 'post', deleteData)
Mock.mock('http://localhost/user', 'post', userData)
Mock.mock('http://localhost/importlist', 'post', importuserData)
Mock.mock('http://localhost/xueli', 'post', xueliData)
Mock.mock('http://localhost/xuewei', 'post', xueweiData)
Mock.mock('http://localhost/minzu', 'post', minzuData)
Mock.mock('http://localhost/news/list', 'post', homenewsData)
Mock.mock('http://localhost/jiating', 'post', jiatingData)
Mock.mock('http://localhost/jianli', 'post', jianliData)
Mock.mock('http://localhost/renzhi', 'post', renzhiData)
Mock.mock('http://localhost/person/details', 'post', personData)
Mock.mock('http://localhost/jianli/details', 'post', jianliDetailData)
Mock.mock('http://localhost/jiating/details', 'post', jiatingDetailData)
Mock.mock('http://localhost/dept/tree', 'post', TreeData)
Mock.mock('http://localhost/unit/list', 'post', TreeData)
Mock.mock('http://localhost/dept/moreDetails', 'post', deptDetailData)
Mock.mock('http://localhost/bz', 'post', bzData)
Mock.mock('http://localhost/bz/details', 'post', bzDetailData)
Mock.mock('http://localhost/dept', 'post', deptData)
Mock.mock('http://localhost/dept/details', 'post', deptDetailData1)
Mock.mock('http://localhost/posts', 'post', postsData)
Mock.mock('http://localhost/posts2', 'post', postsData2)
Mock.mock('http://localhost/posts/detail', 'post', postsdetailData)
Mock.mock('http://localhost/dept/personlist', 'post', deptpersonsData)
Mock.mock('http://localhost/doc/doclist', 'get', docsData)
Mock.mock('http://localhost/doc/doclistmore', 'post', moredocsData)
Mock.mock('http://localhost/unit/unitdetails', 'post', deptDetailData)
Mock.mock('http://localhost/unit/list0', 'post', TreeData0)
Mock.mock('http://localhost/account/userlist', 'post', userListData)
Mock.mock('http://localhost/api/selection/search', 'post', selectionListData)
Mock.mock('http://localhost/account/login', 'post', loginData)
Mock.mock('http://localhost/api/selection/searchunit/', 'post', unitData)
Mock.mock('http://localhost/api/selection/checkunitname/', 'post', checkresultData)
Mock.mock('http://localhost/api/selection/dongyi/savepersonlist/', 'post', checkresultData)
Mock.mock('http://localhost/api/selection/dongyi/save/', 'post', checkresultData)
